export default class PageResult<T> {
  current: number
  size: number
  list: T[]
  total: number

  constructor(current: number, size: number, list: T[], total: number) {
    this.current = current
    this.size = size
    this.list = list
    this.total = total
  }

  static builder<T>(current: number, size: number, list: T[], total: number) {
    return new PageResult(current, size, list, total)
  }
}
